
package DBLayer;
import ModelLayer.ProductDescription;
import ModelLayer.Product;
import java.util.ArrayList;

/**
 * @version 12/22/2011
 * @author Gruppe 4
 */

public interface IFDBProduct {
     // get all products
    public ArrayList<ProductDescription> getAllProductDescriptions(boolean retriveAssociation); 
    //public ArrayList<Product> findProducts(String proType, String wClause, boolean retrieveAssociation, String productType);
    public ArrayList<ProductDescription> findProductDescriptionPType(String proType, boolean retrieveAssociation);
    //get one product having a specified product id
    //public ProductDescription findProduct(int productId, boolean retriveAssociation);
    
    public ProductDescription findProductDescription(int proDescId, boolean retrieveAssociation);
    
    public int deleteProduct(int productId);
    
    public int insertProduct(ProductDescription proDesc, Product pro) throws Exception;
    
    public int updateProduct(Product pro);    
    //find one product having a specified name
    public ProductDescription SearchProductName(String name, boolean retriveAssociation);
    public int getMaxId();
}